Processing method for image tensor data

ABSTRACT

A processing method for image tensor data, which can greatly reduce the number of free parameters in the model, limit the weight layer flexibly, and can be applied to any order of image tensor data. In this processing method for image tensor data, TTRBM model of Restricted Boltzmann machine with tensor train format is introduced. The input and output data of this method are both represented by tensors, and the weight of the middle layer is also represented by tensors, and the restricted weight has the structure of tensor train. The number of free parameters in the middle layer is controlled by adjusting the rank of tensor train decomposition. The rank of TT decomposition is adjusted, and different feature representations with the same size are expressed.

CROSS REFERENCE TO THE RELATED APPLICATIONS

This application is based upon and claims priority to Chinese Patent Application No. CN201910042613.4, filed on Jan. 17, 2019, the entire contents of which are incorporated herein by reference.

TECHNICAL FIELD

The present invention relates to the technical field of data processing, and particularly to a processing method for image tensor data, which can be directly applied to any order of image tensor data.

BACKGROUND

Restricted Boltzmann machine (RBM) is a two-layer neural network composed of visible layer and hidden layer. Because of its strong ability of feature representation, RBM is widely used in pattern recognition and machine learning. In traditional RBM, both visible and hidden layer data are represented in vector form.

However, today data from real life often has multi-dimensional characteristics. In order to apply RBM to these multi-dimensional data, the common method is to vectorize the data. The process of vectorizing often destroys the internal structure of multi-dimensional data, leading to the loss of important association information, or the problem of dimensional disaster. In addition, RBM is a model with fully connected network structure. With the growth of data dimension, the parameters in the model will grow exponentially. Therefore, more storage space and higher computational complexity are needed, which makes RBM algorithm not suitable for ordinary devices or multi-dimensional data applications.

SUMMARY

The technical problem addressed by the present invention is to overcome the deficiency in the prior art, and to provide a processing method for image tensor data, which can greatly reduce the number of free parameters in the model, limit the weight layer flexibly, and can be applied to any order of image tensor data.

The technical solution of the present invention is that, in this processing method for image tensor data, TTRBM model of Restricted Boltzmann machine with tensor train format is introduced. The input and output data of this method are both represented by tensors, and the weight of the middle layer is also represented by tensors, and the restricted weight has the structure of tensor train. The number of free parameters in the middle layer is controlled by adjusting the rank of tensor train decomposition. The rank of TT decomposition is adjusted, and different feature representations with the same size are expressed.

The model input and output data of the invention are both represented by tensors, and the weight of the middle layer is also represented by tensors. In order to reduce the weight quantity of the middle layer, the weight in the invention is limited to have the structure of tensor train. The number of free parameters in the middle layer is controlled by adjusting the rank of tensor train decomposition. The number of free parameters in the weight layer increases linearly with the dimension of sample data, so the number of free parameters in the model is greatly reduced, and the restriction of weight layer is flexible, which can be applied to any order of image tensor data.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows some original digit images and their reconstruction images.

FIG. 2 shows a comparing result between original images (in the FERET database) and reconstructed images.

FIG. 3 is a flow chart according to a preferred embodiment of the invention.

DETAILED DESCRIPTION OF THE EMBODIMENTS

In this processing method for image tensor data, TTRBM model of Restricted Boltzmann machine with tensor train format is introduced. The input and output data of this method are both represented by tensors, and the weight of the middle layer is also represented by tensors, and the restricted weight has the structure of tensor train. The number of free parameters in the middle layer is controlled by adjusting the rank of tensor train decomposition. The rank of TT decomposition is adjusted, and different feature representations with the same size are expressed.

The model input and output data of the invention are both represented by tensors, and the weight of the middle layer is also represented by tensors. In order to reduce the weight quantity of the middle layer, the weight in the invention is limited to have the structure of tensor train. The number of free parameters in the middle layer is controlled by adjusting the rank of tensor train decomposition. The number of free parameters in the weight layer increases linearly with the dimension of sample data, so the number of free parameters in the model is greatly reduced, and the restriction of weight layer is flexible, which can be applied to any order of image tensor data.

Preferably, energy function for TTRBM model is formula (1):

$\begin{matrix} {{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)} = {{- \left\langle {\mathcal{X},{\mathfrak{B}}} \right\rangle} - \left\langle {\mathcal{Y},C} \right\rangle - {\sum\limits_{\underset{j_{1},\;\ldots\mspace{14mu},j_{D}}{i_{1},\;\ldots\mspace{14mu},i_{D}}}^{\;}{{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}{\mathcal{Y}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\mspace{14mu}\ldots\mspace{14mu}{G_{D}\left\lbrack {i_{D},j_{D}} \right\rbrack}}}}} & (1) \end{matrix}$

Where X∈

^(I), y∈

^(J) are tensor visible and hidden units, respectively, both of them are binary variables. In the network, b∈R^(I) and c∈

^(J) are the biases, W∈

^(I×J) is the parameter matrix connecting visible and hidden units. Denoting all model parameter as Θ={b, c, W}. Where G_(d)[i_(d), j_(d)] is an r_(d−1)×r_(d) matrix and G_(d) is r_(d−1)×I_(d)×J_(d)×r_(d) array. The sequence {r_(d)}_(d=0) ^(D) is the TT-ranks of the TT-format of W. Based on the above-mentioned energy function, the joint distribution of

and

can be defined as

${p\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)} = {\frac{1}{Z(\Theta)}\mspace{14mu}\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}$

Where Θ denotes bias B,C, and all the model parameter matrices {G_(d)[i_(d), j_(d)]}_(d=1) ^(D). In the above-mentioned joint distribution, Z(Θ) is the normalization constant and defined by

${Z(\Theta)} = {\sum\limits_{{\mathcal{X} \in \;{\mathbb{X}}},{\mathcal{Y} \in {\mathbb{Y}}}}{\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}}$

Where

and

represent the binary value spaces of

and

, respectively.

Preferably, in formula (1), over all the other variables, the conditional density of each visible unit

(i₁, . . . , i_(D)) can be deduced by

$\begin{matrix} {{p\left( {{{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)} = {1❘\mathcal{Y}}};\Theta} \right)} = {\sigma\left( {{\sum\limits_{j_{1},\;\ldots\mspace{14mu},j_{D}}^{\;}{{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\mspace{14mu}\ldots\mspace{14mu}{G_{D}\left\lbrack {i_{D},j_{D}} \right\rbrack}{\mathcal{Y}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)}}} + {\mathcal{B}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}} \right)}} & (2) \end{matrix}$

And over all the other variables, the conditional density of each hidden unit

(j₁, . . . , j_(D)) can be deduced by

$\begin{matrix} {{p\left( {{{\mathcal{Y}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)} = {1❘\mathcal{X}}};\Theta} \right)} = {\sigma\left( {{\sum\limits_{i_{1},\;\ldots\mspace{14mu},i_{D}}^{\;}{{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\mspace{14mu}\ldots\mspace{14mu}{G_{D}\left\lbrack {i_{D},j_{D}} \right\rbrack}{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}}} + {\mathcal{C}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)}} \right)}} & (3) \end{matrix}$

Where σ is sigmoid function and σ(x)=1/(1+e^(−x)).

Preferably, supposing

={

₁, . . .

_(N)} is observed dataset, the log likelihood of dataset is defined as follows under the joint distribution:

$l = {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{\log\left( {\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{\exp\left\{ {- {E\left( {\mathcal{X}_{n},\mathcal{Y}} \right)}} \right\}}} \right)}}} - {\log\;{Z(\Theta)}}}$

With respect to any parameter θ in Θ is

$\frac{\partial l}{\partial\theta} = {{{- \frac{1}{N}}{\sum\limits_{n = 1}^{N}\;{\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}❘\mathcal{X}_{n}};\Theta} \right)}\frac{\partial{E\left( {\mathcal{X}_{n},{\mathcal{Y};\Theta}} \right)}}{\partial\theta}}}}} + {\sum\limits_{{x^{\prime} \in {\mathbb{X}}},{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}}{{p\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}\frac{\partial{E\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}}}$

Collecting a series of sample sets by means of Gibbs sampling, first, selecting a sample

_(n) ⁽⁰⁾ from the training sample set as initialization and then obtain by iterative sampling {(X _(n) ⁽⁰⁾,

_(n) ⁽⁰⁾),(X _(n) ⁽¹⁾,

_(n) ⁽¹⁾), . . . ,(X _(n) ^((k)),

_(n) ^((k))), . . . }

Replace the model expectation by {

_(n) ^((k))}_(n=1) ^(N).

$\begin{matrix} {\frac{\partial l}{\partial\theta} \approx {{{- \frac{1}{N}}{\sum\limits_{n = 1}^{N}\;{\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}❘\mathcal{X}_{n}};\Theta} \right)}\frac{\partial{E\left( {\mathcal{X}_{n},{\mathcal{Y};\Theta}} \right)}}{\partial\theta}}}}} + {\frac{1}{N}{\sum\limits_{n = 1}^{N}\;{\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}^{\prime}❘\mathcal{X}_{n}^{(k)}};\Theta} \right)}\frac{\partial{E\left( {\mathcal{X}_{n}^{(k)},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}}}}}} & (4) \end{matrix}$

Denoting two notations i_(d) ⁻:=(i₁, . . . ,i_(d−1)) and i_(d) ⁺=(i_(d+1), . . . , i_(D)), therefore, core matrices are respectively P _(d) ⁻[Î _(d) ⁻ ,ĵ _(d) ⁻]:=G ₁[i ₁ ,j ₁] . . . G _(d−1)[i _(d−1) ,j _(d−1)] and P _(d) ⁺[i _(d) ⁺ ,j _(d) ⁺]:=G _(d+1)[i _(d+1) ,j _(d+1)] . . . G _(D)[i _(D) ,j _(D)]

The derivative for formula (1) with respect to the core matrix G_(d)[ĩ_(d),{tilde over (j)}_(d)] is

$\begin{matrix} {\frac{\partial{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}} = {- {\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{\mathcal{X}\left( {i_{d}^{-},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}{\mathcal{Y}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}} & (5) \end{matrix}$

Because

or

is binary variable, the probability of

=1 is actually the mean value of

. By inserting formula (5) into formula (3), the bias derivative of likelihood function to G_(d)[ĩ_(d),{tilde over (j)}_(d)] is

$\begin{matrix} {\frac{\partial l}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}\;{\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{p\left( {{{\mathcal{Y}_{n}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)} = {1❘\mathcal{X}_{n}}};\Theta} \right)} \times {\mathcal{X}_{n}\left( {i_{d}^{-},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}} - {\frac{1}{N}{\sum\limits_{n = 1}^{N}\;{\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{p\left( {{{\mathcal{Y}_{n}^{(l)}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)} = {1❘\mathcal{X}_{n}^{(k)}}};\Theta} \right)} \times {\mathcal{X}_{n}^{(k)}\left( {i_{d}^{-},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}}}} & (6) \end{matrix}$

For the bias parameters, obtain

$\begin{matrix} {\frac{\partial l}{\partial\mathcal{B}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}\;\mathcal{X}_{n}}} - {\frac{1}{N}\mathcal{X}_{n}^{(k)}\mspace{14mu}{and}}}} & (7) \\ {\frac{\partial l}{\partial C} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}\;{p\left( {{\mathcal{Y}_{n} = {1❘\mathcal{X}_{n}}};\Theta} \right)}}} - {\frac{1}{N}{\sum\limits_{n = 1}^{N}\;{{p\left( {{\mathcal{Y}_{n}^{(k)} = {1❘\mathcal{X}_{n}^{(k)}}};\Theta} \right)}.}}}}} & (8) \end{matrix}$

Preferably, the processing method for image tensor data including the following steps:

(1) Given the training dataset

={

₁, . . . ,

_(N)} consisting of N tensors samples, the maximum iteration number T(default value=10000) and ϵ, the learning rate α (default value=0.05), the weight regularizer β (default value=0.01), the momentum γ (default value=0.5), the batch size b (default value=100), and the CD step K (default value=1).

(2) Initializing G_(d)[i_(d), j_(d)] randomly, B=0, C=0 and ΔG_(d)[i_(d),j_(d)]=ΔB=ΔC=0.

(3) For t=1:T do:

Divide

into M batches

₁, . . . ,

_(M) of size b randomly, then

For m=1:M do:

fixing current model parameters Θ, rum the Gibbs sampling for all the data

⁽⁰⁾=

∈

_(m).

For k=0:K−1 do

Fixing

^((k)), update

^((k)) according to formula (3);

Fixing

^((k)), update

^((k)) according to formula (2);

end;

Update the gradient increment by using (6)-(8):

${\Delta\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}} = {{{\gamma\Delta}\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}} + {\alpha\left( {{- \frac{\partial l}{\partial{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}}❘_{\mathcal{D}_{M},\mathcal{D}_{m}^{(K)}}{{- \beta}\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}} \right)}}$ ${\Delta\mathcal{B}} = {{\gamma\Delta\mathcal{B}} + {\alpha\left( {{- \frac{\partial l}{\partial\mathcal{B}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}} \right)}}$ ${\Delta\mathcal{C}} = {{\gamma\Delta\mathcal{C}} + {\alpha\left( {{- \frac{\partial l}{\partial\mathcal{C}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}} \right)}}$

Update model parameters: θ→θ+Δθ, end

Computing e(t). If |e(t)−e(t+1)|<ϵ, break:

end.

Preferably, this method is used to describe the generation model of learning a kind of data. This model contains many kinds of data input, which is defined as multimodal TTRBM.

Preferably, in the training phrase, five matrix patches (X, Z¹, Z², Z³, Z⁴) are used as a training sample. X represents a high resolution patch, which is the raw image from the luminance Y channel in the YCbCr color space and (Z¹, Z², Z³, Z⁴) are low resolution patches, which are the directives of images in x-,y-,xx-,yy-directions of the Y channel. (X, Z¹, Z², Z³, Z⁴) can be seen as visible units, which are connected to the hidden layer Y. Thus, formula (1) can be

${E\left( {X,Z^{1},\ldots\;,Z^{4},{Y;\Theta}} \right)} = {{- \left\langle {X,B} \right\rangle} - \left\langle {Y,C} \right\rangle - {\sum\limits_{i = 1}^{4}\;\left\langle {Z^{i},A_{i}} \right\rangle} - {\sum\limits_{\underset{j_{1},j_{2}}{i_{1},i_{2}}}{{X\left( {i_{1},i_{2}} \right)}{Y\left( {j_{1},j_{2}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}{G_{2}\left\lbrack {i_{2},j_{2}} \right\rbrack}}} - {\sum\limits_{i = 1}^{4}\;{\sum\limits_{\underset{j_{1},j_{2}}{l_{1}^{i},l_{2}^{i}}}{{Z\left( {l_{1}^{i},l_{2}^{i}} \right)}{Y\left( {j_{1},j_{2}} \right)}{Q_{1}^{i}\left\lbrack {l_{1}^{i},j_{1}} \right\rbrack}{Q_{2}^{i}\left\lbrack {l_{2}^{i},j_{2}} \right\rbrack}}}}}$

The joint distribution becomes

${p\left( {X,Z^{1},\ldots\;,Z^{4},{Y;\Theta}} \right)} = {\frac{1}{Z(\Theta)}\exp\left\{ {- {E\left( {X,Z^{1},\ldots\;,Z^{4},{Y;\Theta}} \right)}} \right\}}$

To obtain training patches, image patches are taken from 69 miscellaneous color images, thus obtain the training set as D={(X₁, Z₁ ¹, Z₁ ², Z ₁ ³, Z₁ ⁴), . . . , (X _(N), Z_(N) ¹, Z _(N) ², Z_(N) ³, Z _(N) ⁴)} and randomly selected N=10000, training patches from the miscellaneous database. The image patch size was fixed to 15*15 with a magnification factor of 2 and the hidden size to 20*20.

In testing phase, giving a low resolution image, its four low resolution feature input Z={Z¹, Z², Z ³, Z⁴} can be obtained. Then an estimated X⁰ of the desired super-resolution patch is obtained by using any simple super-resolution algorithm. Furthermore, X⁰ and Z were used as the inputs of visible layer and the proposed TTRBM training algorithm is run. In this process, the message of the visible layer can be transferred to the hidden layer and getting the variable Y. Moreover, the message of the hidden layer will be transferred back to the visible layer and obtaining the super-resolution units X. Finally, the super-resolution image patch X is obtained after the process reaches equilibrium.

The invention is described in more detail below.

The technical solution adopted by the invention is a processing method for image tensor data based on a limited Boltzmann method, and the specific implementation process of the method is as follows.

Two Dimensional Model Construction

First, TTRBM model of Restricted Boltzmann machine with tensor train format is introduced.

The traditional RBM energy function is defined as E(x,y: Θ)=−x ^(T) Wy−b ^(T) x−c ^(T) y

Where x∈

^(I), y∈

^(J) are tensor visible and hidden units, respectively, both of them are binary variables. In the network, b∈R^(I) and c∈

^(J) are the biases, W∈

^(I×J) is the parameter matrix connecting visible and hidden units. Denoting all model parameter as Θ={b, c, W}. Because the traditional RBM is based on the input and output of vector form, in order to avoid vectorization, the visible and hidden elements of tensor form are introduced, so the energy function can be changed into

${{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}❘} = {{- \left\langle {\mathcal{X},\mathcal{B}} \right\rangle} - \left\langle {\mathcal{Y},\mathcal{C}} \right\rangle - {\sum\limits_{\underset{j_{1},\ldots,j_{\mathcal{D}}}{i_{1},\ldots,i_{\mathcal{D}}}}{{\mathcal{X}\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right)}{\mathcal{Y}\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)}{W\left( {\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right),\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)} \right)}}}}$

where

and

are tensor visible and hidden units. The parameters connecting (i₁, . . . , i_(D))-th visible unit and (j₁, . . . , j_(D))-th hidden unit can be represented as W((i₁, . . . , i_(D)), (j₁, . . . , j_(D))) with i_(d)=1, . . . , I_(d) and j_(d)=1, . . . , J_(d) _(o)

A major problem of fully connected layers in high-order RBM is the excessively large number of free parameters. To control the number of parameters, we introduce the TT-layer in an RBM, by assuming that the weight “matrix” W is represented in TT-format with the cores G_(d)[i_(d), j_(d)] (d=1, 2, . . . , D). Thus, the bilinear energy function takes the following tensor form:

$\begin{matrix} {{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)} = {{- \left\langle {\mathcal{X},\mathcal{B}} \right\rangle} - \left\langle {\mathcal{Y},\mathcal{C}} \right\rangle - {\sum\limits_{\underset{j_{1},\ldots,j_{\mathcal{D}}}{i_{1},\ldots,i_{\mathcal{D}}}}{{\mathcal{X}\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right)}{\mathcal{Y}\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\ldots\;{G_{\mathcal{D}}\left\lbrack {i_{\mathcal{D}},j_{\mathcal{D}}} \right\rbrack}}}}} & (1) \end{matrix}$

Where G_(d)[i_(d), j_(d)] is an r_(d−1)×r_(d) matrix and G_(d) is an r_(d−1)×I_(d)×J_(d)×r_(d) array. The sequence {r_(d)}_(d=0) ^(D) is the TT-ranks of the TT-format of W. Based on (1), the joint distribution of x and y can be defined as

${p\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)} = {\frac{1}{Z(\Theta)}\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}$

Where Θ denotes bias B,C, and all the model parameter matrices {G_(d)[i_(d),j_(d)]}_(d=1) ^(D). In the joint distribution, Z(Θ) is the normalization constant and defined by

${Z(\Theta)} = {\sum\limits_{{\mathcal{X} \in {\mathbb{X}}},{\mathcal{Y} \in {\mathbb{Y}}}}{\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}}$

Where

and

represent the binary value spaces of

and

, respectively.

Solution of the Model

Before presenting the learning algorithm for TTRBM, we need to introduce the following theory to deduce the conditional probabilistic density of each visible and hidden unit.

THEOREM 1. In the model of TTRBM, over all the other variables, the conditional density of each visible unit

(i₁, . . . , i_(D)) can be deduced by

$\begin{matrix} {{p\left( {{{\mathcal{X}\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right)} = {1❘\mathcal{Y}}};\Theta} \right)} = {\sigma\left( {{\sum\limits_{j_{1},\ldots,j_{\mathcal{D}}}{{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\cdots\;{G_{\mathcal{D}}\left\lbrack {i_{\mathcal{D}},j_{\mathcal{D}}} \right\rbrack}{\mathcal{Y}\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)}}} + {\mathcal{B}\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right)}} \right)}} & (2) \end{matrix}$

And over all the other variables, the conditional density of each hidden unit

(j₁, . . . , j_(D)) can be deduced by

$\begin{matrix} {{p\left( {{{\mathcal{Y}\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)} = {1❘\mathcal{X}}};\Theta} \right)} = {\sigma\left( {{\sum\limits_{i_{1},\ldots,i_{\mathcal{D}}}{{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\cdots\;{G_{\mathcal{D}}\left\lbrack {i_{\mathcal{D}},j_{\mathcal{D}}} \right\rbrack}{\mathcal{X}\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right)}}} + {\mathcal{C}\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)}} \right)}} & (3) \end{matrix}$

Where σ(x)=1/(1+e^(−x)), which is sigmoid function.

Proof. We only need to prove one item because of symmetry of visible and hidden units.

First, we denote

${\mathcal{M}\left( {i_{1},\ldots\;,i_{\mathcal{D}}} \right)} = {{\sum\limits_{j_{1},\ldots,j_{\mathcal{D}}}{{\mathcal{Y}\left( {j_{1},\ldots\;,j_{\mathcal{D}}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\ldots\;{G_{\mathcal{D}}\left\lbrack {i_{\mathcal{D}},j_{\mathcal{D}}} \right\rbrack}}} + {\mathcal{B}\left\lbrack {i_{1},\ldots\;,i_{\mathcal{D}}} \right\rbrack}}$

And take

(i′₁, . . . , i′_(D)) for consideration. Based on Bayes theorem, we have

${p\left( {{{\mathcal{X}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} = {1❘\mathcal{Y}}};\Theta} \right)} = \frac{p\left( {{{\mathcal{X}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} = 1},{\mathcal{Y};\Theta}} \right)}{p\left( {\mathcal{Y};\Theta} \right)}$

Clearly,

$\begin{matrix} {{p\left( {\mathcal{Y};\Theta} \right)} = {\frac{1}{Z(\Theta)}{\sum\limits_{\mathcal{X} \in \;{\mathbb{X}}}{\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}}}} \\ {= {\frac{\exp\left( \left\langle {\mathcal{Y},\mathcal{C}} \right\rangle \right)}{Z(\Theta)}{\sum\limits_{\mathcal{X} \in \;{\mathbb{X}}}{\prod\limits_{i_{1},\;\ldots\mspace{14mu},i_{D}}\;{\exp\left( {{\mathcal{M}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}} \right)}}}}} \\ {= {\frac{\exp\left( \left\langle {\mathcal{Y},\mathcal{C}} \right\rangle \right)}{Z(\Theta)}{\prod\limits_{i_{1},\;\ldots\mspace{14mu},i_{D}}\left( {1 + {{\exp\left( {\mathcal{M}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)} \right)}.}} \right.}}} \end{matrix}\quad$

Assuming X/i′₁, . . . , i′_(D) is the set that contains all the entries except for X (i′₁, . . . , i′_(D)) we can obtain

${p\left( {{{\mathcal{X}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} = {1❘\mathcal{Y}}};\Theta} \right)} = {\frac{\exp\left( \left\langle {\mathcal{Y},\mathcal{C}} \right\rangle \right)}{Z(\Theta)}{\exp\left( {\mathcal{M}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} \right)} \times {\prod\limits_{{({i_{1},\;{\ldots\mspace{14mu} i_{D}}})} \neq {({i_{1}^{\prime},\;\ldots\mspace{14mu},i_{D}^{\prime}})}}{\exp\left( {1 + {\mathcal{M}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}} \right)}}}$

Combining these together gives

${p\left( {{{\mathcal{X}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} = {1❘\mathcal{Y}}};\Theta} \right)} = {\frac{\exp\left( {\mathcal{M}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} \right)}{1 + {\exp\left( {\mathcal{M}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} \right)}} = {\sigma\left( {\mathcal{M}\left( {i_{1}^{\prime},\ldots\mspace{14mu},i_{D}^{\prime}} \right)} \right)}}$

Which is (2) for (i₁, . . . , i_(D))=(i′₁, . . . , i′_(D)).

Supposing

={X₁, . . . , X_(N)} is observed dataset, the log likelihood of dataset is defined as follows under the joint distribution

$l = {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{\log\left( {\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{\exp\left\{ {- {E\left( {\mathcal{X}_{n},\mathcal{Y}} \right)}} \right\}}} \right)}}} - {\log\;{Z(\Theta)}}}$

By calculation, we can obtain that the derivation of likelihood function with respect to any parameter θ in Θ is

$\frac{\partial l}{\partial\theta} = {{{- \frac{1}{N}}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}❘\mathcal{X}_{n}};\Theta} \right)}\;\frac{\partial{E\left( {\mathcal{X}_{n},{\mathcal{Y};\Theta}} \right)}}{\partial\theta}}}}} + {\sum\limits_{{\mathcal{X}^{\prime} \in \;{\mathbb{X}}},{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}}{{p\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}{\frac{\partial{E\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}.}}}}$

The first term of the right-hand side of the above formula can be seen as the data expectation and the second term is the model expectation. Model expectation is difficult to compute, because it involves the summation of all values in the whole space

and

. To avoid this, we can utilize contrastive divergence (CD) learning to approximate model expectation by Gibbs sampling according to the model distribution. First, selecting a sample

_(n) ⁽⁰⁾ from the training sample set as initialization and then we can obtain {

_(n) ⁽⁰⁾,

_(n) ⁽⁰⁾,

_(n) ⁽¹⁾, . . . ,(

_(n) ^((k)),

_(n) ^((k))), . . . }

Therefore, the model expectation can be approximated by samples {

_(n) ^((k))}_(n=1) ^(N) at step k in the CD-k algorithm, that is,

${\left. {{\sum\limits_{{\mathcal{X}^{\prime} \in \;{\mathbb{X}}},{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}}{{p\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}\frac{\partial{E\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}} = {\sum\limits_{\mathcal{X}^{\prime} \in \;{\mathbb{X}}}\left( {\sum\limits_{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}^{\prime}❘\mathcal{X}^{\prime}};\Theta} \right)}\frac{\partial{E\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}} \right)}} \right){p\left( {\mathcal{X}^{\prime};\Theta} \right)}} \approx {\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}^{\prime}❘\mathcal{X}_{n}^{(k)}};\Theta} \right)}{\frac{\partial{E\left( {\mathcal{X}_{n}^{(k)},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}.}}}}}$

Thus obtain

$\begin{matrix} {\frac{\partial l}{\partial\theta} \approx {{{- \frac{1}{N}}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}❘\mathcal{X}_{n}};\Theta} \right)}\;\frac{\partial{E\left( {\mathcal{X}_{n},{\mathcal{Y};\Theta}} \right)}}{\partial\theta}}}}} + {\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}^{\prime}❘\mathcal{X}_{n}^{(k)}};\Theta} \right)}\frac{\partial{E\left( {\mathcal{X}_{n}^{(k)},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}}}}}} & (4) \end{matrix}$

For clarity, define two metrics i_(d) ⁻:=(i₁, . . . i_(d−1)) and i_(d) ⁺:=(i_(d+1), . . . , i_(D)). In the following, we introduce two new notations for the products of core matrices: P _(d) ⁻[i _(d) ⁻ ,j _(d) ⁻]:=G ₁[i ₁ ,j ₁] . . . G _(d_-1)[i _(d−1) ,j _(d−1)] and P _(d) ⁺[i _(d) ⁺ ,j _(d) ⁺]:=G _(d+1)[_(d+1) ,j _(d+1)] . . . G _(D)[i _(D) ,j _(D)]

For the core matrix G_(d)[ĩ_(d),{tilde over (j)}_(d)], we give the calculating process of

$\frac{\partial l}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}}.$ As for other parameters, the derivative can also be calculated similarly. From (1), we have

$\begin{matrix} {\frac{\partial{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}} = {- {\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{\mathcal{X}\left( {i_{d}^{-},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}{\mathcal{Y}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}} & (5) \end{matrix}$

Because

or is

binary variable, the probability of

=1 is actually the mean value of

. Inserting (5) to (3), the derivation of likelihood function with respect to G_(d)[ĩ_(d),{tilde over (j)}_(d)] is obtained

$\begin{matrix} {\frac{\partial l}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{p\left( {{{\mathcal{Y}_{n}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)} = {1❘\mathcal{X}_{n}}};\Theta} \right)} \times {\mathcal{X}_{n}\left( {i_{d}^{\; -},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}} - {\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{p\left( {{{\mathcal{Y}_{n}^{(k)}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)} = {1❘\mathcal{X}_{n}^{(k)}}};\Theta} \right)} \times {\mathcal{X}_{n}^{(k)}\left( {i_{d}^{\; -},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}}}} & (6) \end{matrix}$

Applying the similar approach, for the bias parameters, we obtain

$\begin{matrix} {\frac{\partial l}{\partial\mathcal{B}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}\mathcal{X}_{n}}} - {\frac{1}{N}\mathcal{X}_{n}^{(k)}}}} & (7) \\ {and} & \; \\ {\frac{\partial l}{\partial\mathcal{C}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{p\left( {{\mathcal{Y}_{n} = {1❘\mathcal{X}_{n}}};\Theta} \right)}}} - {\frac{1}{N}{\sum\limits_{n = 1}^{N}{p\left( {{\mathcal{Y}_{n}^{(k)} = {1❘\mathcal{X}_{n}^{(k)}}};\Theta} \right)}}}}} & (8) \end{matrix}$

From model (1), we can see that the energy function only relies on the product of parameters G_(d)[i_(d),j_(d)], d=1, . . . . D. One parameter going up in any scale S and the other going down to 1/s do not affect the value of energy function. To avoid this problem, in the log likelihood objective 1, we add a penalty

$\frac{\beta}{2}{{{{\underset{\_}{G}}_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}_{F}^{2}.}$

The learning algorithm of overall CD procedure for TTRBM is summarized in Table 1.

The reconstruction errors between the original sample set and the reconstructed sample set can be defined as

${e(t)} = \frac{\sum\limits_{n = 1}^{N}{{\mathcal{X}_{i} - {\hat{\mathcal{X}}}_{i}^{i}}}_{F}^{2}}{N}$

Where

≈

_(i) ^(k)×₁ G_(1(t)) ^(T) . . . ×_(D)G_(D(1)) ^(T), In addition,

₁ ^(i),

_(i) ^(t) and G_(d) represent the updating results of tth iteration. When iteration steps exceed the maximum iteration number T or the reconstruction error satisfies |e(t)−e(t+1)|<ϵ, the iteration algorithm terminates.

TABLE 1 Algorithm 1: CD-K Algorithm for TTRBM Input: Given the training dataset  

  = { 

₁ , . . . ,  

_(N) } consisting of N tensors samples, the maximum iteration number T (default value = 10000) and ϵ, the learning rate α (default value = 0.05), the weight regularizer β (default value = 0.01), the momentum γ (default value = 0.5), the batch size b (default value = 100), and the CD step K (default value = 1). Output: Parameter set Θ = {B, C, G_(d)[i_(d), j_(d)]}. Initialize:  Initializing G_(d)[i_(d), j_(d)] randomly, B = 0,  

  = 0 and ΔG_(d)[i_(d), j_(d)] = ΔB = ΔC = 0. for t = 1:T do  Divide  

  into M batches  

₁, . . . ,  

_(M) of size b randomly, then for m = 1:M do fixing current model parameters Θ, rum the Gibbs sampling for all the data  

⁽⁰⁾ =  

  ∈  

_(m.) for k = 0:K-1 do Fixing  

^((k)), update  

^((k)) according to formula (3);  

^((k)), update  

^((k)) according to formula (2); end;  Update the gradient increment by using (6) - (8): ${\Delta\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}} = {{{\gamma\Delta}\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}} + {\alpha\left( {{- \frac{\partial l}{\partial{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}{{- \beta}\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}} \right)}}$ $\mspace{284mu}{{\Delta\;\mathcal{B}} = {{{\gamma\Delta}\;\mathcal{B}} + {\alpha\left( {{- \frac{\partial l}{\partial\mathcal{B}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}} \right)}}}$ $\mspace{284mu}{{\Delta\;\mathcal{C}} = {{{\gamma\Delta}\;\mathcal{C}} + {\alpha\left( {{- \frac{\partial l}{\partial\mathcal{C}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}} \right)}}}$ Update model parameters: θ → θ + Δθ end Computing e(t). If '|e(t) − e(t + 1)| < ϵ, break; end

Experiment Test:

1. Reconstruction experiment

We conduct reconstruction experiments to test the convergence of the TTRBM algorithm.

The experimental data are from the following two databases:

-   -   A subset of handwritten digits images from the MNIST database

The digit database contains 0-9 digits with 70,000 labeled images. The images of each digit are captured in grayscale and have a uniform size of 28*28 pixels. In this dataset, there are 60,000 training samples and 10,000 testing samples. In the reconstruction experiment, 2,000 training samples of each digit are selected to test the convergence of TTRBM.

-   -   The FERET face database

This database includes 200 different subjects with seven images per subject. All images are grayscale and cropped and normalized to a resolution of 32*32 pixels. In this experiment, we randomly selected 100 individuals to test the reconstruction error.

We use the default parameters δ, α and β as Algorithm 1. When D=2 and the TT-form rank r=[1,1,1], the TTRBM and MVRBM model are similar to each other. Both parameter layers are actually the product of two matrices, but with different matrix sizes. In the TTRBM model, two matrices G₁ and G₂ are of size I₁×J₁ and I₂×J₂, respectively. However, in the MVRBM model, the sizes of two matrices are J₁ ⁻×I₁ and J₂×I₂, respectively. Thus, we mainly compared the performance of the proposed model against the MVRBM model in reconstruction experiments.

In the first attempt using digit database, we set the size of the hidden matrix variate as 25*25. The maximum number of iteration is T=150.

It is obvious that our algorithm with r=[1,1,1] converged slightly faster than MVRBM. In addition, when we set the TT-rank r=[1,2,1], TTRBM converged much faster than the MVRBM. FIG. 1 shows several original digit images and their corresponding reconstructed images. The reconstruction images of different algorithms have almost the same visual effect. This is because different algorithms converge to almost the same average reconstruction errors. The average reconstruction errors of MVRBM and TTRBM with r=[1,2,1] are 10.2275/(28*28) and 9.7783/(28*28), respectively.

Compared with MVRBM, the superiority of our proposed model is that we can adjust the TT-rank to reconstruct face images. We set r=[1,5,1] and r=[1,10,1]. The reconstruction results are shown that the reconstruction errors of TTRBM with r=[1,5,1] and r=[1,10,1] demonstrate a decreasing trend. It shows that the proposed TTRBM is convergent by adjusting rank r on face images. FIG. 2 shows several original face image and their corresponding reconstructions. It can be seen that MVRBM and TTRBM (r=[1,1,1]) cannot reconstruct the correct face images, however the reconstructed face images by TTRBM with r-=[1,10,1] have much better visual effects.

2. Reconstruction of a Super-Resolution Image

The proposed TTRBM can also be described for learning a generative model of data that consists of multiple and diverse input modalities, which has been defined by Multimodal TTRBM. In this experiment, we test the performance of Multimodal TTRBM model on image super-resolution.

In the training phase, we used five matrix patches (X, Z¹, Z², Z³, Z⁴) as a training sample. X represents a high resolution patch, which is the raw image from the luminance Y channel in the YCbCr color space and (Z¹, Z², Z³, Z⁴) are low resolution patches, which are the directives of images in x-,y-,xx-,yy-derections of the Y channel. (X, Z¹, Z², Z³, Z⁴) can be seen as visible units, which are connected to the hidden layer Y. Thus, we can obtain the following energy function:

${E\left( {X,Z^{1},\ldots\mspace{14mu},Z^{4},{Y;\Theta}} \right)} = {{- \left\langle {X,B} \right\rangle} - \left\langle {Y,C} \right\rangle - {\sum\limits_{i = 1}^{4}{{\left\langle {Z^{i},A_{i}} \right\rangle--}{\sum\limits_{\underset{j_{1},j_{2}}{i_{1},i_{2}}}{{X\left( {i_{1},i_{2}} \right)}{Y\left( {j_{1},j_{2}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}{G_{2}\left\lbrack {i_{2},j_{2}} \right\rbrack}}}}} - {\sum\limits_{i = 1}^{4}{\sum\limits_{\underset{j_{1},j_{2}}{i_{1}^{i},i_{2}^{i}}}{{Z\left( {l_{1}^{i},l_{2}^{i}} \right)}{Y\left( {j_{1},j_{2}} \right)}{Q_{1}^{i}\left\lbrack {l_{1}^{i},j_{1}} \right\rbrack}{{Q_{2}^{i}\left\lbrack {l_{2}^{i},j_{2}} \right\rbrack}.}}}}}$

The joint distribution becomes

${p\left( {X,Z^{1},\ldots\mspace{14mu},Z^{4},{Y;\Theta}} \right)} = {\frac{1}{Z(\Theta)}\exp\left\{ {- {E\left( {X,Z^{1},\ldots\mspace{14mu},Z^{4},{Y;\Theta}} \right)}} \right\}}$

To obtain training patches, we take image patches from 69 miscellaneous color images, which can be downloaded at http://decsai.ugr.es/cvg/dbimagenes/. Thus, we obtain the training set as

={(X₁, Z₁ ¹, Z₁ ², Z ₁ ³, Z₁ ⁴), . . . , (X _(N), Z_(N) ¹, Z _(N) ², Z_(N) ³, Z _(N) ⁴)} and randomly selected N=10,000 training patches from the miscellaneous database. The image patch size was fixed to 15*15 with a magnification factor of 2 and we set the hidden size to 20*20, which gave better results in all the tests conducted. Based on Multimodal TTRBM model, the parameter matrices {G₁[i₁,j₁], G₂[i₂,j₂]}_(i) _(d) _(,j) _(d) ^(I) ^(d) ^(,J) ^(d) and {Q₁ ^(i)[l₁ ^(i),l_(j)], Q₂ ^(i)[l₂ ^(i),j₂]}_(l) _(d) _(i,j) _(d) ^(L) ^(d) ^(i) ^(,J) ^(d) (d=1, 2) can be obtained in the training phase.

In testing phase, giving a low resolution image, its four low resolution feature input Z={Z¹, Z², Z ³, Z⁴} can be obtained. Then we can get an estimated X⁰ of the desired super-resolution patch X by using any simple super-resolution algorithm such as interpolation-based methods. Furthermore, X⁰ and Z were used as the inputs of visible layer can be transferred to the hidden layer and getting the variable Y. Moreover, the message of the hidden layer will be transferred back to the visible layer and obtaining the super-resolution units X. Finally, we get the super-resolution image patch X after the process reaches equilibrium.

Table 2 shows the PSNRs for the classic bicubic interpolation, the SR, MVRBM, and the proposed TTRBM for a number of testing natural images.

TABLE 2 PNSR- PSNR- PSNR- PSNR- Times- Times- Times- Image Bicubic SR MVRBM TTRBM SR MVRBM TTRBM athens 33.2333 34.7536 34.4948 34.4950 555.453 35.234 40.610 anhinga 29.2949 30.4464 30.2720 30.2709 344.539 35.348 40.663 baboon 24.9455 25.7033 25.6939 25.6963 390.406 35.272 42.011 barnfall 30.8737 32.0302 31.9782 31.9782 567.408 34.825 42.657 beeflowr 34.6839 35.6362 35.3203 35.3413 511.712 35.143 39.570 blakeyed 31.7163 33.6690 32.8534 32.8607 325.29 35.429 39.765 blueeye 35.2188 36.3957 36.1106 36.1108 786.426 34.856 40.038 bobcat 33.1525 34.2699 34.1001 34.2112 590.128 35.084 42.312

The above contents are only the preferable embodiments of the present invention, and do not limit the present invention in any manner. Any improvements, amendments and alternative changes made to the above embodiments according to the technical spirit of the present invention shall fall within the claimed scope of the present invention. 

What is claimed is:
 1. A processing method for image tensor data, comprising the steps: introducing a TTRBM model of Restricted Boltzmann machine with a tensor train format, TTRBM is Restricted Boltzmann Machine of Tensor Train; representing input and output data of the processing method by a plurality of tensors; and representing a weight of a middle layer by the plurality of tensors, wherein a restricted weight has a structure of the tensor train; a number of free parameters in a middle layer is controlled by adjusting a rank of a tensor train (TT) decomposition; a rank of TT decomposition is adjusted; and different feature representations with a same size are expressed; an energy function for the TTRBM model is formula (1): $\begin{matrix} {{{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)} = {{- \left\langle {\mathcal{X},{\mathfrak{B}}} \right\rangle} - \left\langle {\mathcal{Y},C} \right\rangle - {\sum\limits_{\underset{j_{1},\;\ldots\mspace{14mu},j_{D}}{i_{1},\;\ldots\mspace{14mu},i_{D}}}^{\;}{{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}{\mathcal{Y}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\mspace{14mu}\ldots\mspace{14mu}{G_{D}\left\lbrack {i_{D},j_{D}} \right\rbrack}}}}},} & (1) \end{matrix}$ wherein x∈

^(I), y∈

^(J) are a plurality of tensor visible and hidden units, respectively, both of the plurality of tensor visible and hidden units are binary variables; a network, b∈R^(I) and c∈

^(J) are a plurality of biases, W∈

^(I×J) is a parameter matrix connecting the plurality of tensor visible and hidden units; denoting all model parameter as Θ={b, c, W}; where G_(d)[i_(d), j_(d)] is an r_(d−1)×r_(d) matrix and G_(d) is r_(d−1)×I_(d)×J_(d)×r_(d) array; the sequence {r_(d)}_(d) ^(D)=0 is the TT-rank of the TT-format of W; based on the energy function, a joint distribution of X and Y is defined as ${{p\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)} = {\frac{1}{Z(\Theta)}\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}},$ wherein Θ denotes bias B, C, and a plurality of model parameter matrices {G_(d)[i_(d), j_(d)]}_(d) ^(D)=1; in the above-mentioned joint distribution, Z(Θ) is a normalization constant and defined by ${{Z(\Theta)} = {\sum\limits_{{\mathcal{X} \in \;{\mathbb{X}}},{\mathcal{Y} \in {\mathbb{Y}}}}{\exp\left\{ {- {E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}} \right\}}}},$ where

and

represent binary value spaces of X and Y, respectively; wherein the processing method for image tensor data is used to describe a generation model of learning a kind of data, and the generation model contains many kinds of data input, wherein the many kinds of data input is defined as a multimodal TTRBM; wherein in a training phrase, five matrix patches (X, Z¹,Z²,Z³, Z⁴) are used as a training sample; X represents a high resolution patch, wherein the resolution patch is the raw image from the luminance Y channel in a YCbCr color space and (Z¹,Z²,Z³, Z⁴) are low resolution patches, wherein the low resolution patches are directives of images in x-,y-,xx-,yy-directions of a Y channel, and (X, Z¹,Z²,Z³, Z⁴) is seen as a plurality of visible units, wherein the plurality of visible units are connected to a hidden layer Y; formula (1) is: ${{E\left( {X,Z^{1},\ldots\mspace{14mu},Z^{4},{Y;\Theta}} \right)} = {{- \left\langle {X,B} \right\rangle} - \left\langle {Y,C} \right\rangle - {\sum\limits_{i = 1}^{4}{{\left\langle {Z^{i},A_{i}} \right\rangle--}{\sum\limits_{\underset{j_{1},j_{2}}{i_{1},i_{2}}}^{\;}{{X\left( {i_{1},i_{2}} \right)}{Y\left( {j_{1},j_{2}} \right)}{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}{G_{2}\left\lbrack {i_{2},j_{2}} \right\rbrack}}}}} - {\sum\limits_{i = 1}^{4}{\sum\limits_{\underset{j_{1},j_{2}}{i_{1}^{i},i_{2}^{i}}}^{\;}{{Z\left( {l_{1}^{i},l_{2}^{i}} \right)}{Y\left( {j_{1},j_{2}} \right)}{Q_{1}^{i}\left\lbrack {l_{1}^{i},j_{1}} \right\rbrack}{Q_{2}^{i}\left\lbrack {l_{2}^{i},j_{2}} \right\rbrack}}}}}},$ the joint distribution becomes ${p\left( {X,Z^{1},\ldots\mspace{14mu},Z^{4},{Y;\Theta}} \right)} = {\frac{1}{Z(\Theta)}\exp\left\{ {- {E\left( {X,Z^{1},\ldots\mspace{14mu},Z^{4},{Y;\Theta}} \right)}} \right\}}$ to obtain a plurality of training patches, a plurality of image patches are taken from 69 miscellaneous color images, thus obtain a training set as D={(X₁, Z₁ ¹, Z₁ ², Z ₁ ³, Z₁ ⁴), . . . , (X _(N), Z_(N) ¹, Z _(N) ², Z_(N) ³, Z _(N) ⁴)} and randomly selected N=10000, the plurality of training patches from a miscellaneous database; an image patch size is fixed to 15*15 with a magnification factor of 2 and a hidden size to 20*20; in testing phase, giving a low resolution image, a four low resolution feature input Z={Z¹, Z², Z ³, Z⁴} is obtained; then an estimated X⁰ of a desired super-resolution patch is obtained by using any simple super-resolution algorithm; and, X⁰ and Z were used as inputs of visible layer and a proposed TTRBM training algorithm is run; in the process, a message of a visible layer is transferred to the hidden layer and getting a variable Y; and, a message of the hidden layer is transferred back to the visible layer and obtaining super-resolution units X; and, the super-resolution image patch X is obtained after the process reaches equilibrium.
 2. The processing method for image tensor data according to the claim 1, in formula (1), over all the other variables, a conditional density of each visible unit X(i₁, . . . , i_(D)) is deduced by $\begin{matrix} {{{p\left( {{{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)} = {1❘\mathcal{Y}}};\Theta} \right)} = {\sigma\left( {{\sum\limits_{j_{1},\;\ldots\mspace{14mu},j_{D}}^{\;}{{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\mspace{14mu}\ldots\mspace{14mu}{G_{D}\left\lbrack {i_{D},j_{D}} \right\rbrack}{\mathcal{Y}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)}}} + {\mathcal{B}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}} \right)}},} & (2) \end{matrix}$ and over all the other variables, the conditional density of each hidden unit Y(j₁, . . . ,j_(D)) is deduced by $\begin{matrix} {{{p\left( {{{\mathcal{Y}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)} = {1❘\mathcal{X}}};\Theta} \right)} = {\sigma\left( {{\sum\limits_{i_{1},\;\ldots\mspace{14mu},i_{D}}^{\;}{{G_{1}\left\lbrack {i_{1},j_{1}} \right\rbrack}\mspace{14mu}\ldots\mspace{14mu}{G_{D}\left\lbrack {i_{D},j_{D}} \right\rbrack}{\mathcal{X}\left( {i_{1},\ldots\mspace{14mu},i_{D}} \right)}}} + {\mathcal{C}\left( {j_{1},\ldots\mspace{14mu},j_{D}} \right)}} \right)}},} & (3) \end{matrix}$ wherein σ is a sigmoid function and σ(x)=1/(1+e ^(−x)).
 3. The processing method for image tensor data according to the claim 2, supposing D={X ₁, . . . , X _(N)} is an observed dataset, a log likelihood of dataset is defined as follows under the joint distribution: ${l = {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{\log\left( {\sum\limits_{n = 1}^{\;}{\exp\left\{ {- {E\left( {\mathcal{X}_{n},\mathcal{Y}} \right)}} \right\}}} \right)}}} - {\log\;{Z(\Theta)}}}},$ with respect to any parameter θ in Θ, is $\frac{\partial l}{\partial\theta} = {{{- \frac{1}{N}}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y} \in {\mathbb{Y}}}^{\;}{{p\left( {{\mathcal{Y}❘\mathcal{X}_{n}};\Theta} \right)}\;\frac{\partial{E\left( {\mathcal{X}_{n},{\mathcal{Y};\Theta}} \right)}}{\partial\theta}}}}} + {\sum\limits_{{\mathcal{X}^{\prime} \in \;{\mathbb{X}}},{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}}{{p\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}\frac{\partial{E\left( {\mathcal{X}^{\prime},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}}}$ collecting a series of sample sets by means of Gibbs sampling, first, selecting a sample X_(n) ⁽⁰⁾ from a training sample set as initialization and then obtain by an iterative sampling {(X _(n) ⁽⁰⁾ ,Y _(n) ⁽⁰⁾),(X _(n) ⁽¹⁾ ,Y _(n) ⁽¹⁾), . . . ,(X _(n) ^((k)) ,Y _(n) ^((k))), . . . } replace a model expectation by {X _(n) ^((k))}_(n=1) ^(N) $\begin{matrix} {{\frac{\partial l}{\partial\theta} \approx {{{- \frac{1}{N}}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y} \in \;{\mathbb{Y}}}{{p\left( {{\mathcal{Y}❘\mathcal{X}_{n}};\Theta} \right)}\;\frac{\partial{E\left( {\mathcal{X}_{n},{\mathcal{Y};\Theta}} \right)}}{\partial\theta}}}}} + {\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\mathcal{Y}^{\prime} \in {\mathbb{Y}}}{{p\left( {{\mathcal{Y}^{\prime}❘\mathcal{X}_{n}^{(k)}};\Theta} \right)}\frac{\partial{E\left( {\mathcal{X}_{n}^{(k)},{\mathcal{Y}^{\prime};\Theta}} \right)}}{\partial\theta}}}}}}},} & (4) \end{matrix}$ denoting two notations i_(d) ⁻:=(i₁, . . . , i_(d−1)) and i_(d) ⁺:=(i_(d+1), . . . , i_(D)), therefore, core matrices are respectively P _(d) ⁻[Î _(d) ⁻ ,ĵ _(d) ⁻]:=G ₁[i ₁ ,j ₁] . . . G _(d−1)[i _(d−1) ,j _(d−1)], and P _(d) ⁺[i _(d) ⁺ ,j _(d) ⁺]:=G _(d+1)[i _(d+1) ,j _(d+1)] . . . G _(D)[i _(D) ,j _(D)], a derivative for formula (1) with respect to the core matrix G_(d)[ĩ_(d),{tilde over (j)}_(d)] is $\begin{matrix} {{\frac{\partial{E\left( {\mathcal{X},{\mathcal{Y};\Theta}} \right)}}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}} = {- {\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{\mathcal{X}\left( {i_{d}^{\; -},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}{\mathcal{Y}\left( {{j_{d}^{\; -}{\overset{\sim}{j}}_{d}},j_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}},} & (5) \end{matrix}$ because y or y′ is a binary variable, a probability of y=1 is a mean value of y; by inserting formula (5) into formula (3), a bias derivative of likelihood function to G_(d)[ĩ_(d),{tilde over (j)}_(d)] is $\begin{matrix} {{\frac{\partial l}{\partial{G_{d}\left\lbrack {{\overset{\sim}{i}}_{d},{\overset{\sim}{j}}_{d}} \right\rbrack}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{p\left( {{{\mathcal{Y}_{n}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)} = {1❘\mathcal{X}_{n}}};\Theta} \right)} \times {\mathcal{X}_{n}\left( {i_{d}^{\; -},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}} - {\frac{1}{N}{\sum\limits_{n = 1}^{N}{\sum\limits_{\underset{j_{d}^{-},j_{d}^{+}}{i_{d}^{-},i_{d}^{+}}}{{p\left( {{{\mathcal{Y}_{n}^{(k)}\left( {j_{d}^{-},{\overset{\sim}{j}}_{d},j_{d}^{+}} \right)} = {1❘\mathcal{X}_{n}^{(k)}}};\Theta} \right)} \times {\mathcal{X}_{n}^{(k)}\left( {i_{d}^{\; -},{\overset{\sim}{i}}_{d},i_{d}^{+}} \right)}\left( {P_{d}^{-}\left\lbrack {i_{d}^{-},j_{d}^{-}} \right\rbrack} \right)^{T}\left( {P_{d}^{+}\left\lbrack {i_{d}^{+},j_{d}^{+}} \right\rbrack} \right)^{T}}}}}}},} & (6) \end{matrix}$ for bias parameters, obtain $\begin{matrix} {{\frac{\partial l}{\partial\mathcal{B}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}\mathcal{X}_{n}}} - {\frac{1}{N}\mathcal{X}_{n}^{(k)}}}},} & (7) \\ {and} & \; \\ {\frac{\partial l}{\partial\mathcal{C}} \approx {{\frac{1}{N}{\sum\limits_{n = 1}^{N}{p\left( {{\mathcal{Y}_{n} = {1❘\mathcal{X}_{n}}};\Theta} \right)}}} - {\frac{1}{N}{\sum\limits_{n = 1}^{N}{{p\left( {{\mathcal{Y}_{n}^{(k)} = {1❘\mathcal{X}_{n}^{(k)}}};\Theta} \right)}.}}}}} & (8) \end{matrix}$
 4. The processing method for image tensor data according to claim 3, comprising the following steps: (1) given a training dataset D={X ₁, . . . , X _(N)} consisting of N tensors samples, a maximum iteration number T (default value=10000) and ϵ, a learning rate α (default value=0.05), a weight regularizer β (default value=0.01), a momentum γ (default value=0.5), a batch size b (default value=100), and a CD step K (default value=1); (2) Initializing G_(d)[i_(d), j_(d)] randomly, B=0, C=0 and ΔG_(d)[i_(d),j_(d)]=ΔB=ΔC=0; (3) for t=1:T, doing the following step: divide D into M batches D ₁, . . . , D _(M) of size b randomly, then for m=1:M, doing the following steps: fixing current model parameters Θ, running the Gibbs sampling for all the data X ⁽⁰⁾=X∈D _(m); for k=0:K−1, doing the following steps: fixing X ^((k)), updating Y ^((k)) according to formula (3); fixing Y ^((k)), updating X ^((k)) according to formula (2); end; updating a gradient increment by using (6)-(8): ${{\Delta\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}} = {{\gamma\;\Delta\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}} + {\alpha\left( {{- \frac{\partial l}{\partial{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}{{- \beta}\;{G_{d}\left\lbrack {i_{d},j_{d}} \right\rbrack}}} \right)}}},{{\Delta\;\mathcal{B}} = {{{\gamma\Delta}\;\mathcal{B}} + {\alpha\left( {{- \frac{\partial l}{\partial\mathcal{B}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}} \right)}}},{{\Delta\;\mathcal{C}} = {{{\gamma\Delta}\;\mathcal{C}} + {\alpha\left( {{- \frac{\partial l}{\partial\mathcal{C}}}❘_{\mathcal{D}_{m},\mathcal{D}_{m}^{(K)}}} \right)}}},$ updating model parameters; θ→θ+Δθ, end computing e(t); if |e(t)−e(t+1)|<ϵ, break; end. 